


import { requestClient } from '#/api/request';


// 习惯列表
export async function $gethabitlist(data: any) {
  return requestClient.get<any>('app/habit', { params: data });
}

// 创建习惯
export async function $createhabit(data: any) {
  return requestClient.post<any>('app/habit', data);
}

// 更新习惯
export async function $updatehabit(data: any, id: any) {
  return requestClient.put<any>(`app/habit/${id}`, data);
}

// 删除习惯
export async function $deletehabit(data: any, id: any) {
  return requestClient.delete<any>(`app/habit/${id}`, data);
}

